package com.itheima.clientAndService01;

import java.io.*;

public class IOClass03 {
    public static void main(String[] args) throws IOException {
        long start = System.currentTimeMillis();
        BufferedInputStream bis = new BufferedInputStream(new FileInputStream("F:\\study\\就业班\\4.jpg"));
        BufferedOutputStream bos = new BufferedOutputStream(new FileOutputStream("F:\\study\\就业班\\kakaxi.jpg"));

        byte[] bytes = new byte[1024];
        int b;
        while ((b = bis.read(bytes)) != -1) {
            bos.write(bytes,0,b);
        }
        long end = System.currentTimeMillis();
        System.out.println("程序运行了" + (end - start) + "毫秒");
    }
}
